package com.mk.seckill.config;


/**
 * RabbitMQ配置类-Direct模式
 *
 * @author: LC
 * @date 2022/3/8 4:56 下午
 * @ClassName: RabbitMQDirectConfig
 */
//@Configuration
public class RabbitMQDirectConfig {
    /**
     * @Author hhwu
     * @Description //TODO 学习rabbitmq,direct模式 ，在交换机绑定队列时，还要指定路由key，这样使得携带特定路由key值的消息可以进到特定的队列
     * @Date 14:49 2022/6/11
     **/

//    private static final String QUEUE01 = "queue_direct01";
//    private static final String QUEUE02 = "queue_direct02";
//    private static final String EXCHANGE = "directExchange";
//    private static final String ROUTINGKEY01 = "queue.red";
//    private static final String ROUTINGKEY02 = "queue.green";
//
//    @Bean
//    public Queue queue01() {
//        return new Queue(QUEUE01);
//    }
//
//    @Bean
//    public Queue queue02() {
//        return new Queue(QUEUE02);
//    }
//
//    @Bean
//    public DirectExchange directExchange() {
//        return new DirectExchange(EXCHANGE);
//    }
//
//    @Bean
//    public Binding binding01() {
//        return BindingBuilder.bind(queue01()).to(directExchange()).with(ROUTINGKEY01);
//    }
//
//    @Bean
//    public Binding binding02() {
//        return BindingBuilder.bind(queue02()).to(directExchange()).with(ROUTINGKEY02);
//    }
}
